package com.mrzhou.job.task;

import com.mrzhou.core.tool.utils.LocalDateUtil;
import org.quartz.JobDetail;
import org.quartz.JobExecutionContext;
import org.quartz.JobExecutionException;
import org.springframework.scheduling.quartz.QuartzJobBean;

import java.io.Serializable;

public class TestTask extends QuartzJobBean implements Serializable {
    @Override
    protected void executeInternal(JobExecutionContext jobExecutionContext) throws JobExecutionException {
        JobDetail jobDetail = jobExecutionContext.getJobDetail();
        System.out.println(jobDetail.getKey().toString() + " : " + LocalDateUtil.getDateFormat(LocalDateUtil.nowTime()));
    }
}
